<?php
require "hrfuns.php";
Valid_Client();

if (isset($_POST["Action"])) {
    $iSQL = GetSQL();

    switch ($_POST["Action"]) {
    
    case "Modify":
        $sqlstr = "update vathis_t"
                . " set va_1_length=" . $_POST["Va_1"]
                . ", va_2_length=" . $_POST["Va_2"]
                . " where em_id = '". $_POST["EmId"] . "'";
        break;
    default:
        exit;
    }


    if (isset($sqlstr) && strlen($sqlstr) > 0) {
        //echo $sqlstr;
        if (! $iSQL->query($sqlstr)) 
            echo $_POST["Action"] . "Failed: $sqlstr";
    }

    $iSQL->close();
}
?>
